<template>
<!-- 积分商品列表组件 -->
<!--components/IntegralGoodsList/IntegralGoodsList.wxml-->
<!-- <view class="con-box"> -->
  <view class="integral-item" @tap="toScoreProdDet" :data-scoreprodid="prod.prodId">
    <view class="img">
      <image :src="prod.pic"></image>
    </view>
    <view class="name">{{prod.prodName}}</view>
    <view class="price">
      <image src="/packageMemberIntegral/static/images/icon/integral-icon.png" class="icon"></image>
      <text class="red-word">{{prod.scorePrice}}{{i18n.integral}}<text v-if="prod.price > 0" decode="true"> + ￥{{prod.price}}</text></text>
    </view>
    <view class="old-price">{{i18n.marketValue}}￥{{prod.oriPrice}}</view>
  </view>
<!-- </view> -->
</template>

<script>

export default {
  data() {
    return {};
  },

  components: {},
  props: {
    prod: Object
  },
  
  computed:{
  	i18n() {
  		return this.$t('index')
  	}
  },
  
  methods: {
	  /**
	   * 跳转积分商品详情
	   */
	  toScoreProdDet:function(e) {
	    const prodId = e.currentTarget.dataset.scoreprodid;
	    uni.navigateTo({
	      url: '/packageMemberIntegral/pages/convertProdDet/convertProdDet?prodId=' + prodId
	    });
	  },
  }
};
</script>
<style>
@import "./IntegralGoodsList.css";
</style>